Skip to content

Refactoring and improvements to bot contributing docs#1627

Open
wookie184 wants to merge 3 commits into
mainfrom
wookie/improve-contributing-docs
Open

Refactoring and improvements to bot contributing docs#1627
wookie184 wants to merge 3 commits into
mainfrom
wookie/improve-contributing-docs

Conversation

@wookie184

@wookie184 wookie184 commented Jun 23, 2026

Copy link
Copy Markdown
Contributor

Rewrite of a bunch of the bot contributing documentation, with some other changes here and there.

Open to any suggestions (including reverting parts/adding bits if it feels too concise now).

Changes:

  • Updated "creating bot account" guide to reflect changes to Dev Portal
    • Documented permissions needed
    • Documented permissions + intents directly in bot.md as well so they are harder to miss
  • Combined "forking" and "cloning" guide into one to consolidate information.
  • In docker guide
    • Added potential error from running with Apple Silicon
    • docker-compose -> docker compose
  • Removed installing-project-dependencies.md
    • uv sync doesn't deserve a whole page.
    • Contained a broken link with pycharm instructions.
  • Fixed instructions for getting discord IDs in obtaining-discord-ids.md
  • Removed setting-test-server-and-bot-account.md as it is a duplicate of creating-bot-account.md and obtaining-discord-ids.md
  • Removed Gitpod suggestion for lancebot (it is now a renamed 'AI' company with no free tier afaict)
  • Rewrote a bunch of bot.md to be more concise and hopefully clearer.

@netlify

netlify Bot commented Jun 23, 2026

Copy link
Copy Markdown

Deploy Preview for pydis-static ready!

Name Link
🔨 Latest commit c0e69e6
🔍 Latest deploy log https://app.netlify.com/projects/pydis-static/deploys/6a3d730664277d00086ef235
😎 Deploy Preview https://deploy-preview-1627--pydis-static.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.
🤖 Make changes Run an agent on this branch

To edit notification comments on pull requests, go to your Netlify project configuration.

@coveralls

coveralls commented Jun 23, 2026

Copy link
Copy Markdown

Coverage Status

coverage: 100.0%. remained the same — wookie/improve-contributing-docs into main

Comment thread pydis_site/apps/content/resources/guides/pydis-guides/contributing/bot.md Outdated
Comment thread pydis_site/apps/content/resources/guides/pydis-guides/contributing/bot.md Outdated
@wookie184 wookie184 force-pushed the wookie/improve-contributing-docs branch from cfbedbd to c0e69e6 Compare June 25, 2026 18:27
@wookie184 wookie184 changed the title Refactoring and improvements to contributing docs Refactoring and improvements to bot contributing docs Jun 25, 2026
@wookie184 wookie184 marked this pull request as ready for review June 25, 2026 18:44
The following are needed to run the bot. Follow the links for installation instructions.

- [uv](https://docs.astral.sh/uv/getting-started/installation/).
- [Python 3.14](https://www.python.org/downloads/). This can be installed [using uv](https://docs.astral.sh/uv/guides/install-python/#installing-python).

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

When you run uv sync the first time it will automagically set up the venv with the appropriate Python version.


To start, ensure you have forked and cloned the [bot repository](https://github.com/python-discord/bot) to your local machine. For help with this, check out our [forking and cloning guide](../forking-and-cloning).

From the root of the cloned repository, run the following command to install the project dependencies:

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
From the root of the cloned repository, run the following command to install the project dependencies:
From the root of the cloned repository, run the following command to set up the virtual environment and install the project dependencies:


You can start your own server and set up channels as you see fit, but for your convenience we have a template for a development server you can use: [https://discord.new/zmHtscpYN9E3](https://discord.new/zmHtscpYN9E3).
It is highly recommended to use our [server template](https://discord.new/zmHtscpYN9E3),
as it allows most configuration to be automatically generated for you.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
as it allows most configuration to be automatically generated for you.
as it allows most of the configuration to be automatically generated for you.

You now have both the bot's code and a server to run it on. It's time for you to connect the two by setting the bot's configuration.

Both `.env` and `.env.server` files we talk about below are ignored by git, so they do not get accidentally commit to the repository.
The bot reads variables for configuration from two files, `.env`, and `.env.server`. These files are ignored by git, as they contain information specific to your local environment.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
The bot reads variables for configuration from two files, `.env`, and `.env.server`. These files are ignored by git, as they contain information specific to your local environment.
The bot reads variables for configuration from two files, `.env`, and `.env.server`. These files are ignored by git, as they contain information specific to your local environment including secrets such as the bot token.

I think it's worthwhile to explicitly point this out here because there might be people who don't understand about the proper handling of secrets.

1. In the `Installation` tab, set `Install Link` to `None` and click `Save Changes`.
1. In the `Bot` tab:

- Turn off the `Public Bot` setting.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

IIRC there were issues with creating the link and inviting when Public Bot was off. I would suggest moving that to after the bot has joined the test server. I will also point out that before Public Bot can be turned off the Guild Install checkbox in the Installation tab must be turned off (which is why there are issues with creating the link and adding the bot to the server.)

After you have created a fork, you will then need to clone the repository to your computer, which is the process
of downloading the repository from GitHub to your local machine. You will need Git installed on your computer to do this.

The following will use the [Sir-Lancebot](https://github.com/python-discord/sir-lancebot/) repository as an example, but the steps are the same for all other repositories.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
The following will use the [Sir-Lancebot](https://github.com/python-discord/sir-lancebot/) repository as an example, but the steps are the same for all other repositories.
The following will use the [Sir-Lancebot](https://github.com/python-discord/sir-lancebot/) repository
as an example, but the steps are the same for all other repositories.

Readability in the .MD file and consistency with the rest of the changes.

2. Fork it to your account.<br>
![Github Fork to User](/static/images/content/contributing/fork_user.png)
3. Later, you will need the Git URL of your forked repository in order to clone it.
In your newly forked repository, copy the Git URL by clicking the green `Code` button, then click the Copy Link button.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we suggest people go to the SSH tab here because the default is still HTML.


# Cloning a Repository

You can clone a repository using the command line directly, or by using your IDEs built-in Git integration. We will cover how to do this with the command line, and with PyCharm's integration.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
You can clone a repository using the command line directly, or by using your IDEs built-in Git integration. We will cover how to do this with the command line, and with PyCharm's integration.
You can clone a repository using the command line directly, or by using your IDEs built-in Git integration.
We will cover how to do this with the command line, and with PyCharm's integration.

---
# Development Environment
If you aren't using Docker, you will need to [install the project's dependencies](../installing-project-dependencies) yourself.
From the root of the cloned repository, run the following command to install the project dependencies:

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
From the root of the cloned repository, run the following command to install the project dependencies:
From the root of the cloned repository, run the following command to set up the virtual environment and install the project dependencies:

# Development environment

[Install the project's dependencies](../installing-project-dependencies/)
From the root of the cloned repository, run the following command to install the project dependencies:

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
From the root of the cloned repository, run the following command to install the project dependencies:
From the root of the cloned repository, run the following command to set up the virtual environment and install the project dependencies:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants